package com.candy.excep;

import java.io.FileInputStream;
import java.io.FileNotFoundException;

public class Test07 {
    public static void main(String[] args) {
        test03();
    }


    public static void test03() {
        int num01=6;
        if(num01==6){
            throw new NullPointerException();
        }

    }


    public static void test02() {
        try {
            test01();
        } catch (FileNotFoundException e) {
            System.out.println("文件未找到异常");
        }
    }
//手动抛出异常
    public static void test01() throws FileNotFoundException {
        FileInputStream file01=new FileInputStream("");
    }






}
